import 'package:flutter/cupertino.dart';
import 'package:mobile_app.core/core/presentation/widgets/app_button.dart';

class AppIconButton extends StatelessWidget {
  const AppIconButton({
    required this.icon,
    required this.onPressed,
    required this.width,
    required this.height,
    this.iconPadding = EdgeInsets.zero,
    super.key,
  });

  final Widget icon;
  final VoidCallback? onPressed;
  final double width;
  final double height;
  final EdgeInsets iconPadding;

  @override
  Widget build(BuildContext context) {
    return AppButton(
      onPressed: onPressed,
      child: SizedBox(
        height: height,
        width: width,
        child: Padding(
          padding: iconPadding,
          child: icon,
        ),
      ),
    );
  }
}
